The present invention relates to a counter circuit, and more particularly to a counter circuit used in a system for inputting positional information into a data processing apparatus.
Among Input/Output peripheral systems for the data processing apparatus, a wide variety of positional information input systems are utilized, for example, as a so-called "mouse" for a personal computer and as a numerical position detector in a drafting machine, a NC machine and an industrial robot. The positional information is generally detected in form of electrical pulse signals which are applied to a counter circuit to be counted. The counter circuit outputs the counted digitial data to the data processing apparatus as an input positional information. The counting operation of the counter circuit is executed in response to the detection of the positional information, while the output operation of the counter circuit to the data processing apparatus is performed by a read-command signal generated by the data processing apparatus.
A predetermined operation time is necessary in the counter circuit for the counting operation. If the read-command signal is applied during the counting operation, the outputted data bears meaningless information. Since there is no specific relationship between the counting operation and the read-command signal timing, the read-command signal is applied from time to time during the counting operation of the counter. In such a case, the bits before the counting operation and the bits after the counting operation co-exist in mixture in the output of the counter circuit and hence the output becomes meaningless.
It is possible to synchronize the counting operation of the counter circuit with the read-command signal by using such sampling clocks in detection of the positional information to obtain pulse signals that is in synchronism with the clock signal used in the data processing apparatus. However, in such a case, a clock which is in synchronism with the data processing apparatus must be generated inside a chip. Therefore, the circuit construction becomes complicated.